Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add localization entry for location_too_far #733

Merged

Conversation

navarchus
Copy link
Contributor

address #649 (Tested, works on fabric)

@object-Object
Copy link
Member

oh, huh.

location: {
too_far: "%s is out of range",
out_of_world: "%s is not within the world",
too_close_to_out: "%s is too close to the boundary of the world",
forbidden: "%s is forbidden to you",
bad_dimension: "This dimension forbids that action",
},

override fun errorMessage(ctx: CastingEnvironment, errorCtx: Context): Component =
error("location_$type", Vec3Iota.display(location))
}

So the actual bug is that the keys in the file are eg. hexcasting.mishap.location.too_far (with a period), but the mishap is constructing keys like hexcasting.mishap.location_too_far (with an underscore).

On 1.19, these keys used an underscore, so I think the best fix would be to update the file to match.

We should be able to do that just by changing this line from location: { to "location_": { .

@navarchus
Copy link
Contributor Author

yep that works lol

@object-Object
Copy link
Member

cool cool
actually, I guess we may as well also update the other lang files (zh_cn, ru_ru) with the same change if you can? I should have mentioned it before, sorry

@object-Object
Copy link
Member

lmfao thanks

@object-Object object-Object disabled auto-merge August 23, 2024 17:49
@object-Object object-Object merged commit aa02f75 into FallingColors:main Aug 23, 2024
4 checks passed
@navarchus navarchus deleted the fix-missing-location-too-far branch August 23, 2024 17:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

2 participants